package com.redmoon.weixin.mgr;

import com.alibaba.fastjson.JSONObject;
import com.cloudweb.oa.api.IWorkWeixinService;
import com.cloudweb.oa.utils.SpringUtil;
import com.cloudwebsoft.framework.util.LogUtil;
import cn.js.fan.util.StrUtil;
import cn.js.fan.web.Global;
import com.redmoon.oa.account.AccountDb;
import com.redmoon.oa.flow.MyActionDb;
import com.redmoon.oa.person.UserDb;
import com.redmoon.weixin.Config;
import com.redmoon.weixin.config.Constant;

import javax.servlet.http.HttpServletRequest;

/**
 * @Description:
 * @author:
 * @Date: 2016-8-8下午03:34:57
 */
public class WXMessageMgr extends WXBaseMgr {
    public static enum MESSAGE_TYPE_ENMU {
        NOTICE, SYSMSG, MSG, FLOW
    }

    public final static String TEXT_TYPE = "text";

    public int sendTextMessage(String userName, String content, String action, MESSAGE_TYPE_ENMU message_enum) {
        IWorkWeixinService workWeixinService = SpringUtil.getBean(IWorkWeixinService.class);
        return workWeixinService.sendTextMessage(userName, content, action, message_enum);
    }
}
